package cn.tedu;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("car")
public class CarController {
    @RequestMapping("get")
    public Car getCar(){
        Car car = new Car();
        car.setId(718);
        car.setName("保时捷");
        car.setType("Cayman T");
        car.setColor("红色");
        car.setPrice(641000.0);
        return car;
    }
    @RequestMapping("get03")
    public void get03(Car car){
        System.out.println(car.getId()+ "\t"+car.getName() +"\n"+car.getType());
    }

}
